package org.zjx.data.screen;

import org.zjx.command.entity.screen.Room;
import org.zjx.data.BaseSceneBuilder;

import java.awt.*;

public class TianGongSceneBuilder extends BaseSceneBuilder {

    @Override
    protected String getSceneName() {
        return "天宫";
    }

    @Override
    protected Dimension getSceneSize() {
        return new Dimension(252, 167);
    }

    @Override
    protected void addMonsters() {

    }

    @Override
    protected void addNpcs() {
        addNpc("守门天将", new Point(239, 18));
        addNpc("守门天将", new Point(230, 13));
        addNpc("接引仙子", new Point(162, 66));
        addNpc("素衣仙女", new Point(100, 25));
        addNpc("顺风耳", new Point(101, 63));
        addNpc("天牢守卫", new Point(229, 141));
        addNpc("水兵统领", new Point(170, 140));
        addNpc("大力神灵", new Point(18, 129));
        addNpc("马真人", new Point(227, 71));
        addNpc("斩妖台守卫", new Point(32, 113));
        addNpc("斩妖台守卫", new Point(40, 116));
        addNpc("守门道童", new Point(21, 23));
        addNpc("守门道童", new Point(29, 27));
    }

    @Override
    protected void addRooms() {
        Room lingXiaoBaoDian = createRoom("凌霄宝殿", new Dimension(99, 74));
        addNpcToRoom(lingXiaoBaoDian, "玉皇大帝", new Point(28, 46));
        addNpcToRoom(lingXiaoBaoDian, "王母娘娘", new Point(35, 49));
        addNpcToRoom(lingXiaoBaoDian, "李靖", new Point(30, 36));
        addNpcToRoom(lingXiaoBaoDian, "杨戬戬", new Point(55, 26));
        addNpcToRoom(lingXiaoBaoDian, "哪吒", new Point(66, 33));
        rooms.add(lingXiaoBaoDian);

        Room douShuaiGong = createRoom("兜率宫", null);
        addNpcToRoom(douShuaiGong, "太上老君", new Point(20, 20));
        addNpcToRoom(douShuaiGong, "炼丹道士", new Point(37, 16));
        rooms.add(douShuaiGong);
    }

    @Override
    protected void addTeleports() {
        addSceneTeleport(new Point(236, 16), "长寿郊外", new Point(26, 58), new Point(226, 13));
        addSceneTeleport(new Point(28, 24), "兜率宫", new Point(40, 10), new Point(26, 25));
        addSceneTeleport(new Point(10, 66), "蟠桃园", new Point(147, 5), new Point(4, 66));
        addSceneTeleport(new Point(152, 60), "凌霄宝殿", new Point(76, 17), new Point(147, 64));
        addSceneTeleport(new Point(38, 163), "月宫", new Point(118, 9), new Point(32, 165));

        addRoomTeleport(new Point(28, 24), "兜率宫", new Point(40, 10), new Point(26, 25));
        addRoomTeleport(new Point(152, 60), "凌霄宝殿", new Point(76, 17), new Point(147, 64));
    }

    public static void main(String[] args) {
        new TianGongSceneBuilder().execute("tiangong_scene.json", "天宫");
    }
}